<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<f:view xmlns="http://www.w3.org/1999/xhtml"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui"
	xmlns:util="http://java.sun.com/jsf/composite/util">
	<ui:composition template="/views/layouts/main.xhtml">
	<ui:define name="content">
		<h:form id="formPrincipal">
			<div class="grid_18"> 
				<div class="grid_6 ">
					<util:home action="#{atorBean.goHome}" />
				</div>
				<util:titulo value="#{i18n.TituloAtores}" />
				<div class="grid_1">
					<util:help />
				</div>
			</div>
		
			<div class="grid_18">
				<br/>
				<p:dataTable id="dtAtores" widgetVar="dtAtores" value="#{atorBean.atorList}"
					var="model" paginator="true" paginatorPosition="bottom" 
					rows="#{contextoBean.dataTableRows}" paginatorTemplate="#{contextoBean.paginatorTemplate}"
					selection="#{atorBean.atorSelect}" rowsPerPageTemplate="#{contextoBean.rowsPerPage}">
					<f:facet name="header">
						<p:commandButton action="#{atorBean.goDelete}" onclick="dialogoExcluirAtor.show();"
							icon="ui-icon ui-icon-trash" value="#{i18n.btn_Excluir}" style="float:right"/>
						<p:commandButton type="button" onclick="dialogoNovoAtor.show();" 
							icon="ui-icon ui-icon-plus" value="#{i18n.btn_Novo}" style="float:right"/>
						<p:commandButton type="button" onclick="dialogoFiltrarAtor.show();" 
							icon="ui-icon ui-icon-search" value="#{i18n.btn_Filtrar}" style="float:right" />
					</f:facet>
					<p:column headerText="#{i18n.Ator_Nome}">
						<h:outputText value="#{model.nome}" />
					</p:column>
					<p:column headerText="#{i18n.Ator_Acoes}">
						<p:commandButton icon="ui-icon ui-icon-gear" oncomplete="alert('Editar');" />
					</p:column>
					<p:column selectionMode="multiple" />
				></p:dataTable>
			</div>
		</h:form>
		<ui:include src="/views/atores/dialogos.xhtml" />
	</ui:define>
	</ui:composition>
</f:view>